import {computed, defineComponent} from "vue";

export default defineComponent({
    name: "raw-displayer",
    props:{
        title: {
            required: true,
            type: String
        },
        value: {
            required: true
        }
    },
    setup({title,value},){
        const valueString=computed(()=>{
            return JSON.stringify(value, null, 2);
        })
        return ()=>(<div>
            <h3>{ title }</h3>
            <pre>{ valueString.value }</pre>
        </div>)
    },
})